import java.util.Arrays;
import java.util.Scanner;

public class E3TE {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int E = scanner.nextInt();
        int[][] matrix = new int[N+1][N+1];
        for (int i = 1; i <= N ; i++) {
            for (int j = 1; j <= i; j++) {
                if(i==j) {
                    matrix[i][j] = 0;
                    matrix[j][i] = matrix[i][j];
                }else {
                    matrix[i][j] = 100000;
                    matrix[j][i] = matrix[i][j];
                }
            }
        }
        for (int i = 0; i < E; i++) {
            int num1 = scanner.nextInt();
            int num2 = scanner.nextInt();
            matrix[num1][num2] = 1;
            matrix[num2][num1] = 1;
        }
        for (int k = 1; k <= N; k++) {
            for (int i = 1; i <= N; i++) {
                for (int j = 1; j < i; j++) {
                    matrix[i][j] = Math.min(matrix[i][j],matrix[i][k]+matrix[k][j]);
                    matrix[j][i] = matrix[i][j];
                }
            }
        }
        scanner.nextLine();
        String str = scanner.nextLine();
        String[] num = str.split(" ");
        float sum;boolean[] isVisted = new boolean[N+1];
        for (int i = 0; i < num.length; i++) {
            if(isVisted[Integer.valueOf(num[i])]) {
                continue;
            }
            sum = 0;isVisted[Integer.valueOf(num[i])] = true;
            for (int j = 1; j <= N; j++) {
                sum+=matrix[j][Integer.valueOf(num[i])];
            }
            System.out.printf("Cc(%d)=%.2f ",Integer.valueOf(num[i]),(N-1)/sum);
        }
    }
}
